import { Message } from "@arco-design/web-vue";


const handleCopy = async (text: string, message = "复制成功!") => {
  var aux = document.createElement("input");
  aux.setAttribute("value", text);
  document.body.appendChild(aux);
  aux.select();
  document.execCommand("copy");
  document.body.removeChild(aux);
  Message.success(message);
};

export { handleCopy };